import React from 'react';
import Message from './message';
import Header from './header';
import Aside from './aside';
import Body from './body';

// import global style.
require('../style/base');

// hide wechat share button.
function onBridgeReady() {
    var WeixinJSBridge = WeixinJSBridge;
    WeixinJSBridge.call('hideOptionMenu');
}
if (typeof WeixinJSBridge === 'undefined') {
    if (document.addEventListener) {
        document.addEventListener('WeixinJSBridgeReady', onBridgeReady, false);
    } else if (document.attachEvent) {
        document.attachEvent('WeixinJSBridgeReady', onBridgeReady);
        document.attachEvent('onWeixinJSBridgeReady', onBridgeReady);
    }
} else {
    onBridgeReady();
}

export default class Main extends React.Component {
    render() {
        return (
            <div>
                <Header />
                <Message />
                <Body />
                <Aside />
            </div>
        )
    }
}
